import request from '@/utils/request.js'

// 查询所有投诉
export const getAllComplaints = () => {
  return request.get('/complaints/all')
}

// 更新投诉信息
export const updateComplaints = (complaints) => {
  return request.put('/complaints', complaints)
}

// 删除投诉信息   
export const deleteComplaints = (id) => {
  return request.delete('/complaints/' + id);
}

// 投诉处理
export const addComplaintHandling = (data) => {
  return request.post('/complaintHandling', data);
}